<template>
  <!-- 沪深市场：主要指数、深市指数、沪市指数 -->
  <el-row class="clearfix">
    <el-col :span="4">
      <Navtab/>
    </el-col>
    <el-col :span="20">
      <!-- <h1>Welcome</h1> -->
      <!-- <span>{{' 路由传参:'+indexType}}</span> -->
      <!-- <span>{{' 全局变量:'+$store.state.indexType}}</span> -->
      <HSMarket/>
    </el-col>
  </el-row>
  
</template>

<script>
import HSMarket from "../../../components/fore/market/HSMarket"
import Navtab from "../../../components/fore/common/Navtab"

export default {
  props:['indexType'],
  data() {
    return {}
  },
  computed:{
    watchURLChange(){

    }
  },
  // indexType利用监听器
  watch:{
    indexType:function(newVal,oldVal){
      // this.sCode=newVal
      // this.stockID
      // this.indexCode=newVal;
      // console.log(this.indexCode);
    this.$store.commit('setIndexType',newVal)

    }
  },
  created:function () {
    this.$store.commit('setIndexType',this.indexType)
  },
  components:{
    Navtab,
    HSMarket
  }
}
</script>

<style>
</style>
